/// <reference path="node.d.ts" />

import * as URL from 'url';

let myUrl = URL.parse("http://www.typescriptlang.org");

console.log( myUrl.pathname )

console.log(myUrl.hostname)